/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package Classes;

import java.util.ArrayList;
import java.util.Objects;

/**
 * Encapsule une liste de reservations
 * @author ZwoRmi
 */
public class Reservations {
    ArrayList<Reservation> _reservations;
    /**
     * Constructors
     */
    public Reservations() {
        this.setReservations(new ArrayList<Reservation>());
    }

    public Reservations(ArrayList<Reservation> reservations) {
        this.setReservations(reservations);
    }
    /**
     * Getters and setters
     */
    public ArrayList<Reservation> getReservations() {
        return _reservations;
    }

    public void setReservations(ArrayList<Reservation> _reservations) {
        this._reservations = _reservations;
    }
    /**
     * Equals
     * @param obj
     * @return true si equals
     */
    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final Reservations other = (Reservations) obj;
        if (!Objects.equals(this._reservations, other._reservations)) {
            return false;
        }
        return true;
    }
    
}
